<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>ChildFeed</title>
<link
	href='http://fonts.googleapis.com/css?family=Signika+Negative:300,400,600,700'
	rel='stylesheet' type='text/css'>

<link rel="stylesheet" type="text/css" href="./styles/jquery.qtip.min.css" />
<link rel="stylesheet" type="text/css" href="./styles/jquery-ui-custom.css" />
<link rel="stylesheet" type="text/css" href="./styles/jquery.multiselect.css" />
<link rel="stylesheet" href="./styles/token-input-facebook.css"
	type="text/css" />
<link rel="stylesheet" type="text/css" href="./styles/general.css"
	media="screen" />
<? if ($mobile): ?>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<? endif; ?>
<script
	type="text/javascript"
	src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
<script
	type="text/javascript"
	src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.9/jquery-ui.min.js"></script>
<script
	type="text/javascript" src="./scripts/jquery.qtip.min.js"></script>
	<script
	type="text/javascript" src="./scripts/jquery.multiselect.js"></script>
<script
	src="./scripts/jquery.ui.touch-punch.min.js"></script>
<script
	type="text/javascript" src="./scripts/IDcard.js"></script>
<script
	type="text/javascript" src="./scripts/toasts.js"></script>
<script
	type="text/javascript" src="./scripts/jquery.tokeninput.js"></script>
<script
	type="text/javascript" src="./scripts/LogCard.js"></script>
<script
	type="text/javascript" src="./scripts/LunchCard.js"></script>
<script
	type="text/javascript" src="./scripts/ArchiveEntry.js"></script>
	<script
	type="text/javascript" src="./scripts/replaceAll.js"></script>
<? if ($currentPage["script"] != ""): ?>
<script type="text/javascript" src="<?=$currentPage["script"];?>"></script>
<? endif; ?>
</head>
<body ontouchstart="">
	<header<?=($currentPage["hasHead"]) ? " class=\"withHead\"" : ""; ?>>
		<a class="title" href="?pg=home">ChildFeed</a>
		<div class="user">Dan Donald</div>
	</header>
	<nav>
		<ul>
		<? foreach ($pages as $page): ?>
		<? if ($page['onMenu']==true): ?>
			<li>
			  <a href="?pg=<?=$page['url']?>"<?=($currentPage['url'] == $page['url']) ? " class=\"current\"" : "" ?>><?=$page['name']?></a>
			</li>
		<? endif; ?>
		<? endforeach; ?>
		</ul>
	</nav>
	<? if ($currentPage["hasHead"]==true): ?>
	<div class="pageHead<?=($currentPage["sidebar"]!="") ? " withSidebar" : ""; ?>">
	<? if ($currentPage["button"] != ""): ?>
	  <? if ($currentPage["button"] == "submit"): ?>
	  <input type="submit" id="btnSubmit" value="Submit" title="Save and publish your reports to the parents" />
	  <? elseif ($currentPage["button"] == "publish"): ?>
	  <input type="submit" id="btnSubmit" value="Publish Story" title="Save and publish the story to the parents" />
	  <? elseif ($currentPage["button"] == "back"): ?>
	  <input type="button" id="btnOk" value="Back to Home" title="Return to the home page with the changes you made intact" />
	  <? endif; ?>
	<? endif; ?>
		<h3><?=$currentPage["name"]?></h3>
	</div>
	<? endif; ?>
	<? if ($currentPage["sidebar"]!=""): ?>
	<div class="sidebar">
		<?php 
		include($currentPage["sidebar"]);
		?>
	</div>
	<? endif; ?>
	<div class="content<?=($currentPage["hasHead"]) ? "" : " noHead"; ?><?=($currentPage["sidebar"]!="") ? " withSidebar" : ""; ?>">
		<span id="toast"></span><span id="error"></span>
		<?php 
		include($currentPage["file"]);
		?>
	</div>
</body>
</html>